LassoScript Utility
Basics Browse Detail

[Date->Week]

Tag Link [Date->Week] Category Date
Type Member Source Available No
Support Preferred Version 6.0
Change Unchanged Data Source Any
Output Type Integer Security None
Implementation LCAPI Sets Lasso 8.5, Lasso 8.0, Lasso 7.0, Lasso 6.0

Description

[Date->Week] returns the integer week from 1 to 53 for a specified Lasso date/time object. Note that either the first or last week of the year may fall partly in the previous or next year. In this case the first days of the year may be part of week 52 or week 53 or the last days of the year may be part of week 1. Weeks in Lasso start on Sunday by default. The optional parameter -Monday will make the [Date->Week] tag correspond with the ISO standard for weeks.

Syntax

[(Date)->Week]

[(Date)->(Week: -Monday)]

Parameters

Optional Parameters
-Monday Uses Monday as the start day for determining week numbers.

Examples

To return the week number from a Lasso date:

The following example returns the week number from the Lasso date 12/30/2002.

[(Date:'12/30/2002')->Week]

52